home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1995 October
/
EnigmA AMIGA RUN 01 (1995)(G.R. Edizioni)(IT)[!][issue 1995-10][Aminet 7].iso
/
Aminet
/
comm
/
mebbs
/
fb.lha
/
fb.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1994-11-12
|
2KB
|
94 lines
/* Build a FLO file by Larry Cloud M3001 */
start1:
cls=""
say cls||"FLO Builder by Larry Cloud M3001"
say "Enter address (4D) separated by spaces, example: 1 350 31 0"
say "Or hit Q to abort."
if zone ~="ZONE" then do
say "Or hit enter for "||zone||" "||net||" "||node||" "||point||"."
end
pull adr
if adr="" & zone ~="ZONE" then signal start2
if upper(adr)="Q" then signal getout
parse var adr zone net node point junk
if zone < 1 then signal start
if net="" | node="" then signal start1
if point="" then point="0"
if exists("ram:nodeinfo") then do
address command "delete ram:nodeinfo quiet"
do i=1 to 1000;end
end
address command "findnode "||zone||":"||net||"/"||node||"."||point||" > ram:nodeinfo"
do i=1 to 1000;end
open(file,"ram:nodeinfo",'r')
do i=1 to 5
x=readln(file)
end
x=readln(file)
if x~=" Data not found." then do
do i=1 to 4
x=readln(file)
say x
end
call close(file)
signal start2
end
call close(file)
say "That address is invalid. Please try again."
zone="ZONE"
signal start1
start2:
path="OUT:"
say "Enter filename to add to the FLO (or hit ENTER to abort)"
pull filename
if filename="" then signal start5
if exists("OUT:"||filename) then do
say"File '"||filename||"' already exists in OUT: use this path? (Y/n)"
pull question
question=upper(question)
if question="N" then do
signal start3
end
signal start4
end
start3:
say "Enter FULL path to file (do NOT include file name, end path with : or /)"
say "(or use Q to abort)"
pull path
path=upper(path)
if path="Q" then signal start5
if right(path,1) ~=":" & right(path,1)~="/" then signal start3
if ~exists(path||filename) then do
say "File does NOT exist in that path. Try again!"
signal start3
end
start4:
op="W"
adrs=zone||"."||net||"."||node||"."||point||".FLO"
if exists("OUT:"||adrs) then op="A"
string="Creating new "
if op="A" then string="Appending to "
say string||"FLO file "||adrs
open(file,"OUT:"||adrs,op)
writeln(file,path||filename)
close(file)
start5:
say "Again? (Y/n)"
pull question
if upper(question)="N" then signal getout
signal start1
getout:
say "You've been using FLO Builder by Larry Cloud M3001"
if exists("ram:nodeinfo") then do
address command "delete ram:nodeinfo quiet"
do i=1 to 1000;end
end
exit